assert_matches
Provides a macro, assert_matches, which tests whether a value matches a given pattern, causing a panic if the match fails.
extern crate assert_matches; let a = A; assert_matches!; assert_matches!; To include in your project, only when tests are compiled, add the following to your Cargo.toml:
[] = "1.5" And add the following to your crate root:
extern crate assert_matches; License
assert_matches is distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT for details.